{php}
$CmsMenuList = $dataArr['CmsMenuList']; // 栏目
$CmsDetail = $dataArr['CmsDetail']; // 详情
$CmsRandomData = $dataArr['CmsRandomData']; // 随机文章
$pageInfos = $pageInfo; // 页面信息
$cssDetails = "yes"; // 详情页css
$pageInfoList = $pageInfo; // 列表页要用的栏目信息
$jsDetails = "yes"; // 详情页代码高亮js
{/php}
{include file="header" pageInfos="$pageInfos" CmsMenuList="$CmsMenuList" cssDetails="$cssDetails"/}
    <article class="details">
        <div class="layui-row">
            <div class="layui-col-md9 Clear content">
                <div class="layui-col-md12 Clear">
                    <div class="layui-col-md12 Clear body">
                        <div class="layui-col-md12 Clear listHead Border">
                            <div class="layui-col-md14 Clear left">
                                <img src="{$CmsDetail.headimg |default='__static__/img/noimg.jpg'}" alt="{$pageInfoList.keywords}">
                            </div>
                            <div class="layui-col-md8 Clear right">
                                <h1>{$CmsDetail.title}</h1>
                                <h2>{$CmsDetail.easytitle}</h2>
                                <div class="info">
                                    <span>{$CmsDetail.onclick}人已围观</span>
                                    <span style="margin: 0 5px">{$CmsDetail.likenum}人赞</span>
                                    <span class="timeType">{$CmsDetail.newtime}</span>
                                </div>
                                <div class="Tag-row1">
                                    {if ( $CmsDetail.tagname !== '[]')}
                                        <span>标签:</span>
                                        {volist name="$CmsDetail.tagname" id="tag"}
                                        <a href="/tag/{$tag.id}-1.html">{$tag.name}</a>
                                        {/volist}
                                    {/if}
                                </div>
                                <div class="more">
                                    <div>
                                        <span style="margin-right: 5px">作者: {$CmsDetail.writer |default="匿名"}</span>
                                        <span>来源: {$CmsDetail.befrom |default="转载"}</span>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <!--head end-->
                <!--正文区域-->
                <div class="body">
                    {$CmsDetail.content |raw}
                </div>
                <!--正文区域 end-->
                <!--赞-->
                <div class="diggit" data_id="{$CmsDetail.id}">
                    <span> 很赞哦！ </span>
                    (<b id="likeNum">{$CmsDetail.likenum}</b>)
                </div>
                <!--赞 end-->
                <!--评论-->
                <div class="pinglun">
                    <fieldset class="layui-elem-field layui-field-title" style="text-align: center;">
                        <legend>评论区</legend>
                    </fieldset>
                    <ul class="content flexC" id="pinglunUl">
                        <!--<li class="flexC">
                            <div class="flexR">
                                <img src="https://q.qlogo.cn/qqapp/101235792/5D1C3AFF34C73E1DBC6B01C5CA4755FF/100" alt="">
                                <div class="flexC">
                                    <span>0ERROR</span>
                                    <span>5小时前</span>
                                </div>
                            </div>
                            <div>
                                <i>@</i><span style="color: #01AAED;">HiTerry</span>
                                这段代码用了一年多，每天用几百次都是没问题的。就突然出现闪屏后后台显示提交了20多次
                            </div>
                            <div class="flexR">
                                <span class="zan flexR">
                                    <span></span>
                                    <span>1</span>
                                </span>
                                <span class="msg flexR">
                                    <span></span>
                                    <span>回复</span>
                                </span>
                            </div>
                        </li>-->
                    </ul>
                    <div class="pageInfo" style="text-align: center;margin: 5px 0">
                        <div id="page"></div>
                    </div>
                    <div class="editDiv">
                        <input type="text" id="name" autocomplete="off" placeholder="请输入昵称 (必填)" class="layui-input">
                        <div id="edit"></div>
                        <button id="fasong" type="button" class="layui-btn" style="margin-top: 20px;padding: 0 35px;">发送</button>
                        <button type="button" id="fasongStatus" class="layui-btn" style="margin-top: 20px;padding: 0 23px;cursor: no-drop;background-color: #33baaf;display: none">发送中...</button>
                        <button type="button" id="update" class="layui-btn layui-btn-primary" style="margin-top: 20px;padding: 0 35px;"><i class="layui-icon">&#xe669;</i></button>
                    </div>
                </div>
                <!--评论 end-->
                <div class="layui-col-md12 publicHead random Clear">
                    <div>
                        <h2><span>随机图文</span></h2>
                        <div class="blockBody">
                            {volist name="$CmsRandomData" id="data"}
                            <div class="layui-col-md3 Clear">
                                <a href="/detail/{$data.id}.html">
                                    <img src="{$data.headimg |default='__static__/img/noimg.jpg'}" alt="{$data.title}" title="{$data.title}">
                                    <h1 title="item.title">{$data.title}</h1>
                                    <p title="item.easyinfo">{$data.easytitle}</p>
                                    <div><span class="timeType">{$data.newtime}</span><span class="more">+文章阅读</span></div>
                                </a>
                            </div>
                            {/volist}
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </article>
<script src="__static__/lib/wangEditor/wangEditor.min.js" type="application/javascript"></script>
<script type="application/javascript">
    var E = window.wangEditor;
    var editor = new E('#edit');
    // 自定义菜单配置
    editor.customConfig.menus = [
        'emoticon',  // 表情
        'image',  // 插入图片
        'foreColor',  // 文字颜色
        'link',  // 插入链接
        'quote',  // 引用
        // 'code',  // 插入代码
    ];
    // 表情面板可以有多个 tab ，因此要配置成一个数组。数组每个元素代表一个 tab 的配置
    editor.customConfig.emotions = [
        {
            // tab 的标题
            title: '大黄脸',
            // type -> 'emoji' / 'image'
            type: 'image',
            // content -> 数组
            content: [
                {
                    alt: '[可爱]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/09/2018new_keai_org.png'
                },
                {
                    alt: '[太开心]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/1e/2018new_taikaixin_org.png'
                },
                {
                    alt: '[鼓掌]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/6e/2018new_guzhang_org.png'
                },
                {
                    alt: '[嘻嘻]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/33/2018new_xixi_org.png'
                },
                {
                    alt: '[哈哈]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/8f/2018new_haha_org.png'
                },
                {
                    alt: '[笑cry]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/4a/2018new_xiaoku_thumb.png'
                },
                {
                    alt: '[挤眼]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/43/2018new_jiyan_org.png'
                },
                {
                    alt: '[馋嘴]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/fa/2018new_chanzui_org.png'
                },
                {
                    alt: '[哼]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/7c/2018new_heng_org.png'
                },
                {
                    alt: '[怒]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/f6/2018new_nu_org.png'
                },
                {
                    alt: '[委屈]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/a5/2018new_weiqu_org.png'
                },
                {
                    alt: '[可怜]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/96/2018new_kelian_org.png'
                },
                {
                    alt: '[失望]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/aa/2018new_shiwang_org.png'
                },
                {
                    alt: '[悲伤]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/ee/2018new_beishang_org.png'
                },
                {
                    alt: '[害羞]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/c1/2018new_haixiu_org.png'
                },
                {
                    alt: '[污]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/10/2018new_wu_org.png'
                },
                {
                    alt: '[爱你]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/f6/2018new_aini_org.png'
                },
                {
                    alt: '[亲亲]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/2c/2018new_qinqin_org.png'
                },
                {
                    alt: '[色]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/9d/2018new_huaxin_org.png'
                },
                {
                    alt: '[憧憬]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/c9/2018new_chongjing_org.png'
                },{
                    alt: '[舔屏]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/3e/2018new_tianping_org.png'
                },{
                    alt: '[坏笑]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/4d/2018new_huaixiao_org.png'
                },{
                    alt: '[阴险]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/9e/2018new_yinxian_org.png'
                },{
                    alt: '[笑而不语]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/2d/2018new_xiaoerbuyu_org.png'
                },{
                    alt: '[偷笑]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/71/2018new_touxiao_org.png'
                },{
                    alt: '[酷]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/c4/2018new_ku_org.png'
                },{
                    alt: '[并不简单]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/aa/2018new_bingbujiandan_org.png'
                },{
                    alt: '[思考]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/30/2018new_sikao_org.png'
                },
                {
                    alt: '[疑问]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/b8/2018new_ningwen_org.png'
                },
                {
                    alt: '[晕]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/07/2018new_yun_org.png'
                },
                {
                    alt: '[衰]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/a2/2018new_shuai_org.png'
                },
                {
                    alt: '[嘘]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/b0/2018new_xu_org.png'
                },
                {
                    alt: '[闭嘴]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/62/2018new_bizui_org.png'
                },
                {
                    alt: '[傻眼]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/dd/2018new_shayan_org.png'
                },
                {
                    alt: '[吃惊]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/49/2018new_chijing_org.png'
                },
                {
                    alt: '[拜拜]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/fd/2018new_baibai_org.png'
                },
                {
                    alt: '[鄙视]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/da/2018new_bishi_org.png'
                },
                {
                    alt: '[白眼]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/ef/2018new_landelini_org.png'
                },
                {
                    alt: '[抓狂]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/17/2018new_zhuakuang_org.png'
                },
                {
                    alt: '[互粉]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/86/2018new_hufen02_org.png'
                },
                {
                    alt: '[吃瓜]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/01/2018new_chigua_org.png'
                },
                {
                    alt: '[doge]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/a1/2018new_doge02_org.png'
                },
                {
                    alt: '[二哈]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/22/2018new_erha_org.png'
                },
                {
                    alt: '[喵喵]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/7b/2018new_miaomiao_org.png'
                },
            ]
        },
        {
            // tab 的标题
            title: '热门',
            // type -> 'emoji' / 'image'
            type: 'image',
            // content -> 数组
            content: [
                {
                    alt: '[鲜花]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/d4/2018new_xianhua_org.png'
                },
                {
                    alt: '[男孩儿]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/0a/2018new_nanhai_org.png'
                },
                {
                    alt: '[女孩儿]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/39/2018new_nvhai_org.png'
                },
                {
                    alt: '[兔子]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/c6/2018new_tuzi_org.png'
                },
                {
                    alt: '[太阳]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/cd/2018new_taiyang_org.png'
                },
                {
                    alt: '[月亮]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/d5/2018new_yueliang_org.png'
                },
                {
                    alt: '[赞啊]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/00/lxhzan_thumb.gif'
                },
                {
                    alt: '[羞嗒嗒]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/df/lxhxiudada_org.gif'
                },
                {
                    alt: '[好爱哦]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/74/lxhainio_org.gif'
                },
                {
                    alt: '[偷乐]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/fa/lxhtouxiao_thumb.gif'
                },

                {
                    alt: '[笑哈哈]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/32/lxhwahaha_org.gif'
                },
                {
                    alt: '[好喜欢]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/d6/lxhlike_thumb.gif'
                },{
                    alt: '[求关注]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/ac/lxhqiuguanzhu_org.gif'
                },
                {
                    alt: '[佩奇]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/c6/hot_pigpeiqi_org.png'
                },
                {
                    alt: '[大侦探皮卡丘微笑]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/b3/pikaqiu_weixiao_org.png'
                },
                {
                    alt: '[给你小心心]',
                    src: 'http://img.t.sinajs.cn/t4/appstyle/expression/ext/normal/ca/qixi2018_xiaoxinxin_org.png'
                },
            ]
        },
        {
            title: 'emoji',
            type: 'emoji',
            content: ['😀','😁','😂','😃','😄','😅','😆','😉','😊','😋','😎','😍','😘','😗','😙','😚','😐','😑',
                '😶','😏','😣','😥','😮','😯','😪','😫','😴','😌','😛','😜','😝','😒','😓','😔','😕','😲','😷','😖','😞','😟','😤',
                '😢','😭','😦','😧','😨','😬','😰','😱','😳','😵','😡','😠','🌹','🍀','🍎','💰','📱','🌙','🍁','🍂','🍃','🌷','💎','🔪','🔫','🏀','⚽','⚡','👄','👍','🔥']
        }
    ];
    editor.customConfig.pasteFilterStyle = true; // 开启粘贴样式的过滤
    editor.customConfig.pasteIgnoreImg = true; // 禁止粘贴图片
    // 自定义处理粘贴的文本内容
    editor.customConfig.pasteTextHandle = function (content) {
        // content 即粘贴过来的内容（html 或 纯文本），可进行自定义处理然后返回
        return '<p>'+content+'</p>'
    };
    editor.create();
    editor.txt.html('<span>文明上网 理性发言</span>');
</script>
{include file="footer" jsDetails="$jsDetails"/}